because we are already inside the ValueError exception handler, so we know that
the give device identifier is not an integer, and DevController.destroyDevice
only accepts integers. Fixes bug #315.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
if self.readBackend(i, 'dev') == devid:
DevController.destroyDevice(self, i)
return
- # Try this, but it's almost certainly going to throw VmError,
- # since we can't find the device.
- DevController.destroyDevice(self, int(devid))
+ raise VmError("Device %s not connected" % devid)